<!-- <template>
    <div class="app-container">
        <component :is="pipelineNetwork" />
        <PipelineNetworkCesium @onload="onload" />
    </div>
</template>

<script setup name="Dispatch-cockpit">
import PipelineNetworkCesium from "@/components/PipelineNetworkCesium";
const pipelineNetwork = ref(null);

const onload = async () => {
    const component = await import('@/components/PipelineNetwork');
    pipelineNetwork.value = component.default;
}
</script>

<style scoped lang="scss">
.app-container {
    padding: 0 !important;
    overflow: hidden;
    position: relative;
}
</style> -->


<template>
    <iframe class="iframe" :src="iframeSrc" frameborder="0"></iframe>
</template>

<script setup>

import { ref, watch, onMounted } from 'vue'
import { getToken, setToken } from '@/utils/auth';
import { getDeviceParameter } from '@/api/index';
const iframeSrc = ref('')

getDeviceParameter().then(({data}) => { 
    iframeSrc.value = data + `?route=/pipelineNetworkCesium&adminToken=${getToken()}`
})

</script>
<style>
.iframe{
    width:100%;
    height: 100%;
}
</style>